<template>
  <div v-loading="formLoading">
    <div>
      <div class="fx">
        <div class="block f5bg">
          <div class="block-left">公司名称：</div>
          <div
            class="block-right"
            v-html-no="{ action: basicInfo.enterpriseName }"
          ></div>
        </div>
        <div class="block">
          <div class="block-left">纳税识别号：</div>
          <div
            class="block-right"
            v-html-no="{ action: basicInfo.creditCode }"
          ></div>
        </div>
      </div>
      <div class="fx">
        <div class="block f5bg">
          <div class="block-left">所属行业：</div>
          <div
            class="block-right"
            v-html-no="{ action: basicInfo.industry }"
          ></div>
        </div>
        <div class="block">
          <div class="block-left">注册类型：</div>
          <div
            class="block-right"
            v-html-no="{ action: basicInfo.loginRegisterType }"
          ></div>
        </div>
      </div>
      <div class="fx">
        <div class="block f5bg">
          <div class="block-left">经营状态：</div>
          <div
            class="block-right"
            v-html-no="{ action: basicInfo.businessStatus }"
          ></div>
        </div>
        <div class="block">
          <div class="block-left">组织结构代码：</div>
          <div
            class="block-right"
            v-html-no="{ action: basicInfo.orzCode }"
          ></div>
        </div>
      </div>
      <div class="fx">
        <div class="block f5bg">
          <div class="block-left">登记机关：</div>
          <div
            class="block-right"
            v-html-no="{ action: basicInfo.taxOffices }"
          ></div>
        </div>
        <div class="block">
          <div class="block-left">经营范围：</div>
          <div
            class="block-right"
            v-html-no="{ action: basicInfo.businessScope }"
          ></div>
        </div>
      </div>

      <div class="title-msg">工商信息变更</div>
      <div class="canpanyer-box" style="margin-top: 20px">
        <el-table size="mini" :data="basicInfo.qccEnterpriseChangeList" border>
          <el-table-column align="center" prop="name" label="变更类型">
          </el-table-column>
          <el-table-column align="center" prop="changeDate" label="变更时间">
          </el-table-column>
          <el-table-column align="center" prop="beforeContent" label="变更前">
          </el-table-column>
          <el-table-column align="center" prop="affterContent" label="变更后">
          </el-table-column>
        </el-table>
      </div>
    </div>
  </div>
</template>
<script>
import { getBusinessCirclesDetail } from "@/api/report";
export default {
  name: "basicInfo",
  props: {
    detailInfo: {
      type: Object,
      default: () => {}
    },
    basicInfo: {
      type: Object,
      default: () => {}
    }
  },
  created() {
    // this.getBusinessCirclesDetail();
  },
  data() {
    return {
      // basicInfo: {},
      qccEnterpriseChangeList: [],
      formLoading: false
    };
  },
  methods: {
    getBusinessCirclesDetail() {
      this.formLoading = true;
      let params = {
        reportId: this.detailInfo.id
      };
      getBusinessCirclesDetail(params)
        .then(res => {
          this.basicInfo = res.data;
          this.qccEnterpriseChangeList = res.data.qccEnterpriseChangeList;
          this.formLoading = false;
        })
        .finally(() => {
          this.formLoading = false;
        });
    }
  }
};
</script>

<style scoped lang="scss">
.f5bg {
  background: #f5f5f5;
}
.fx {
  //display: flex;
  align-items: center;
  justify-content: space-between;
  //width: 100%;
  .block {
    //width: 48%;
    display: flex;
    align-items: center;
    min-height: 30px;
    padding: 18px 0;

    //line-height: 56px;
    .block-left {
      width: 120px;
      color: #222;
      font-size: 14px;
      font-weight: bold;
    }
    .block-right {
      display: flex;
      justify-content: flex-start;
      align-items: flex-start;
      font-size: 14px;
      //line-height: 18px;
      color: #999;
      width: 100%;
    }
  }
}
.title-msg {
  font-size: 14px;
  font-weight: bold;
  color: #222222;
  float: left;
  margin-bottom: 20px;
}
</style>
